package cn.dceast.situation.service;

import cn.dceast.situation.dao.SituationMapper;
import cn.dceast.situation.model.Record;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 *
 * Created by zhouxiaa on 2017/7/11.
 */
@Service
public class SituationService {

    @Autowired
    private SituationMapper situationMapper;

    public List<Map> getListByUserId(Map<String, Object> params) {
        return situationMapper.getListByUserId(params);
    }

    public int getCountByUserId(Map<String, Object> params) {
        return situationMapper.getCountByUserId(params);
    }
    public int addRecord(Record record) {
        return situationMapper.insertSelective(record);
    }
}
